/**
 * 
 */
package com.shy.base.util;

import com.alibaba.druid.filter.config.ConfigTools;

/**
 * <p>Title:DruidEncrypt
 * <p>Description:
 * @author H2013788
 * @date 2019年11月7日
 */
public class DruidEncrypt {

	public static void main(String[] args) {
		// 加密
		try {
			String miwenofter = ConfigTools.encrypt("root");
			System.out.println("加密后" + miwenofter);
		} catch (Exception e) {
			e.printStackTrace();
		}
		// 解密
		try {
			String mingwen = ConfigTools.decrypt(
					"bNVOqb7WKLX5Bjnw+LMv92taj25KOxDimXxILPQjw42wgv+1lHzOH8kr97xDwWdhpY67QuYCS7sWN4W46YbkFA==");
			System.out.println("解密后：" + mingwen);
		} catch (Exception e) {
			e.printStackTrace();
		}
	}

	
}
